package edu.nf.relaxenjoy.common.exception;

/**
 * @author zhu
 * @date 2024-10-12
 */
public class GlobalException extends RuntimeException {

    private Integer errorCode;

    public GlobalException(ErrorsEnum e) {
        super(e.errorMessage());
        this.errorCode = e.errorCode();
    }

    public Integer getErrorCode() {
        return errorCode;
    }
}
